window: don't forget to fetch title border when not on CSD
authorCosimo Cecchi <cosimoc@gnome.org>
Sun, 21 Apr 2013 20:56:25 +0000 (16:56 -0400)
committerCosimo Cecchi <cosimoc@gnome.org>
Sun, 21 Apr 2013 20:59:14 +0000 (16:59 -0400)
We still need to respect this border value even when we're not running
under CSD, since we support setting a custom titlebar in all cases.

The border/style magic in gtk_window_draw() really needs to be separated
out into logical pieces soon, but for now let's keep a consistent
behavior with the previous code.

gtk/gtkwindow.c

index 10dfac91e4ba6a901a05e92a4c9ffdf7f6ae874b..48972d9436f5304ad50c47ec8a7a817c04c1a966 100644 (file)
@@ -8892,6 +8892,8 @@ gtk_window_draw (GtkWidget *widget,
 
   if (priv->client_decorated)
     get_decoration_borders (widget, &title_border, &inner_border, &outer_border);
+  else if (priv->title_box != NULL)
+    get_decoration_borders (widget, &title_border, NULL, NULL);
 
   if (!gtk_widget_get_app_paintable (widget) &&
       gtk_cairo_should_draw_window (cr, gtk_widget_get_window (widget)))